package pers.crayon.baseprogram.sign;

import java.util.HashMap;

/**
 * 数字签名与签名校验接口
 */
public interface HttpSigner {
    /**
     * 进行请求内容加密
     *
     * @param request
     * @return
     * @throws Exception
     */
    public String doSign(String request) throws Exception;

    /**
     * 校验数字签名
     *
     * @param content
     * @return
     */
    public boolean doVerify(String content);

    /**
     * 校验数字签名
     *
     * @param result
     * @param signResult
     * @return
     */
    public boolean doVerify(HashMap<String, Object> result, String signResult);
}